package com.chen.retrofitdemo.dao;

import androidx.lifecycle.LiveData;

import com.chen.retrofitdemo.model.Result;
import com.chen.retrofitdemo.model.UserBean;

import retrofit2.Call;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.POST;

/**
 * Created by chenshanshan on 2020/9/26.
 */
public interface UserService {


    @GET("user/hello")
    LiveData<Result<String>> login();

    @FormUrlEncoded
    @POST("user/getToken")
    LiveData<Result<UserBean>> login1(@Field("phone") String phone);

}
